﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ServiceModel;
using AuctionModel;


namespace AuctionServer
{
    [ServiceContract]
    public interface IAuctionService
    {
        [OperationContract]
        void CreateUser(User user);

        [OperationContract]
        User Login(string username, string password);

        [OperationContract]
        void CreateAuction(Auction auction, List<Item> items);

        [OperationContract]
        Auction ShowAuction(int id);

        [OperationContract]
        void PlaceBid(Bid bid);

        [OperationContract]
        void StartAuction(DateTime startTime);

        [OperationContract]
        int GetTopBid(Item item);

        [OperationContract]
        void EndAuction(DateTime endTime);
        
        [OperationContract]
        List<Auction> GetAllAuctions();

        [OperationContract]
        List<Item> GetAllItems();

        [OperationContract]
        void AddItemToAuction(Auction auction, Item item);
    }
}
